package com.liuliu.zua.service.impl;

import com.liuliu.common.utils.DateUtils;
import com.liuliu.zua.domain.ZuaRecruit;
import com.liuliu.zua.mapper.ZuaRecruitMapper;
import com.liuliu.zua.service.IZuaRecruitService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 就业信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-03-22
 */
@Service
@SuppressWarnings("all")
public class ZuaRecruitServiceImpl implements IZuaRecruitService 
{
    @Autowired
    private ZuaRecruitMapper zuaRecruitMapper;

    /**
     * 查询就业信息
     * 
     * @param recruitId 就业信息ID
     * @return 就业信息
     */
    @Override
    public ZuaRecruit selectZuaRecruitById(Long recruitId)
    {
        return zuaRecruitMapper.selectZuaRecruitById(recruitId);
    }

    /**
     * 查询就业信息列表
     * 
     * @param zuaRecruit 就业信息
     * @return 就业信息
     */
    @Override
    public List<ZuaRecruit> selectZuaRecruitList(ZuaRecruit zuaRecruit)
    {
        return zuaRecruitMapper.selectZuaRecruitList(zuaRecruit);
    }

    /**
     * 新增就业信息
     * 
     * @param zuaRecruit 就业信息
     * @return 结果
     */
    @Override
    public int insertZuaRecruit(ZuaRecruit zuaRecruit)
    {
        zuaRecruit.setCreateTime(DateUtils.getNowDate());
        return zuaRecruitMapper.insertZuaRecruit(zuaRecruit);
    }

    /**
     * 修改就业信息
     * 
     * @param zuaRecruit 就业信息
     * @return 结果
     */
    @Override
    public int updateZuaRecruit(ZuaRecruit zuaRecruit)
    {
        zuaRecruit.setUpdateTime(DateUtils.getNowDate());
        return zuaRecruitMapper.updateZuaRecruit(zuaRecruit);
    }

    /**
     * 批量删除就业信息
     * 
     * @param recruitIds 需要删除的就业信息ID
     * @return 结果
     */
    @Override
    public int deleteZuaRecruitByIds(Long[] recruitIds)
    {
        return zuaRecruitMapper.deleteZuaRecruitByIds(recruitIds);
    }

    /**
     * 删除就业信息信息
     * 
     * @param recruitId 就业信息ID
     * @return 结果
     */
    @Override
    public int deleteZuaRecruitById(Long recruitId)
    {
        return zuaRecruitMapper.deleteZuaRecruitById(recruitId);
    }
}
